import request from '@/utils/request'

// 查询活动自定义分类列表
export function listProductActivityCategory(query) {
  return request({
    url: '/product/productActivityCategory/list',
    method: 'get',
    params: query
  })
}

// 查询活动自定义分类列表
export function listProductActivityCategoryByActivityId(query) {
  return request({
    url: '/product/productActivityCategory/listByActivityId',
    method: 'get',
    params: query
  })
}

// 查询活动自定义分类详细
export function getProductActivityCategory(customCategoryId) {
  return request({
    url: '/product/productActivityCategory/' + customCategoryId,
    method: 'get'
  })
}

// 新增活动自定义分类
export function addProductActivityCategory(data) {
  return request({
    url: '/product/productActivityCategory',
    method: 'post',
    data: data
  })
}

// 修改活动自定义分类
export function updateProductActivityCategory(data) {
  return request({
    url: '/product/productActivityCategory',
    method: 'put',
    data: data
  })
}

// 删除活动自定义分类
export function delProductActivityCategory(customCategoryId) {
  return request({
    url: '/product/productActivityCategory/' + customCategoryId,
    method: 'delete'
  })
}
